package com.yundingai.vm.constant;

/**
 * @Author: liyuxiang
 * @Date: 2025/7/18 14:39
 */

public class RedisConstant {
    /**
     * Redis中存储的用户学习计划的前缀
     */
    public static final String PLAN_KEY_PREFIX = "plan:";

    /**
     * Redis中存储的用户学习计划的过期时间，单位为秒
     */
    public static final long PLAN_EXPIRE_TIME = 60 * 60 * 24; // 1天

    /**
     * Redis中存储的用户学习计划的最大数量
     */
    public static final int MAX_PLAN_COUNT = 100;
    /**
     * chat记忆存储的前缀
     */
    public static final String CHAT_MEMORY_PREFIX = "aiChatMemory:";
    /**
     * chatroom存储的前缀
     */
    public static final String CHAT_ROOM_PREFIX = "chatRoom:";

    // 新增的token相关常量
    public static final String USER_LOGIN_KEY = "user:login:";  // 用户登录token key: user:login:{userId} -> token
    public static final String TOKEN_KEY = "token:";           // token对应的用户 key: token:{token} -> userId
    public static final long TOKEN_EXPIRE = 3600 * 24;        // token过期时间24小时
}
